#include "RecordStatusComponent.h"

void RecordStatusComponent::setRecordStatus(RecordStatus status)
{
	switch (status)
	{
		case RECORD_CLOSE:
			this->recordStatusFile = RECORD_0;
			break;
		case RECORD_DOING:
			this->recordStatusFile = RECORD_1;
			break;
		case RECORD_PLAY:
			this->recordStatusFile = RECORD_2;
			break;
		case RECORD_PAUSE:
			this->recordStatusFile = RECORD_3;
			break;
		default:
			break;
	}
}

void RecordStatusComponent::doRender()
{
	string path = NAVI_ICON_FILE(recordStatusFile);
	lcd.drawBmpFile(SD, path.c_str(), RECORD_POS_X, RECORD_POS_Y);
}

RecordStatusComponent::RecordStatusComponent() : ViewComponent(false)
{
	this->recordStatusFile = RECORD_0;
}


RecordStatusComponent::~RecordStatusComponent()
{
}
